<?php
/**
 * Created by PhpStorm.
 * User: yangliqiang
 * Date: 2018/9/18
 * Time: 22:48
 */

namespace console\controllers;

use Cm;
use yii\console\Controller;

class BaseController extends Controller
{
    public $wxAccount = [];
    public function __construct($id, Module $module, array $config = [])
    {
        parent::__construct($id, $module, $config);

        $wxAccount = Cm::$db->all("SELECT id, accountappid FROM `scrm_weixin_account` WHERE  status=1 and accountverifytype <> -1");
        if ($wxAccount) {
            $this->wxAccount = $wxAccount;
        }
    }
}